using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class CameraSetting : MonoBehaviour
{
    public GameObject backGround;
    public GameObject loadPanel;
    public GameObject gameOverPanel;

    void Awake()
    {
        Camera.main.orthographicSize = Camera.main.orthographicSize * 1080 / 1920 * Screen.height / Screen.width;
        if (backGround != null)
        {
            float bili=(float)1920/1080*Screen.width/Screen.height;
            float x=backGround.transform.localScale.x*1920/Screen.height/bili;
            float y = backGround.transform.localScale.y * 1080 / Screen.width/bili;
            backGround.transform.localScale = new Vector3(x, y, 1);
        }
        
        Application.targetFrameRate = 120;
    }
}
